<%@ page language="java" pageEncoding="UTF-8"%>
<%@ include file="IncludeHeader.jsp"%>
<html>
  <head>
    <title>网上书店</title>
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    <meta http-equiv="description" content="This is my page">
    <link rel="stylesheet" type="text/css" href="<html:rewrite page="/style.css"/>">
  </head>
  <body>
    <div class="content">
    <%@ include file="IncludeTop.jsp"%>
   <div class="cart">
   <table border="0" width="100%">
      	<tr>
   			<td>发货人：${orderForm.shiptoname} <td>
   		</tr>
   		<tr>
   			<td>发货地址：${orderForm.shipaddress} <td>
   		</tr>
   </table>
	<table border="0" width="100%">
	<tr class="tr_head">
		<td>书名</td>
		<td>售价</td>
		<td>折扣</td>
		<td>折后价格</td>
		<td>数量</td>
	</tr>
	
	<logic:present name="cartForm">
		<logic:iterate id="item" collection="${ cartForm.cart.cartItemList.pageList }">
			<tr>
				<td>${item.item.itemId}</td>
				<td>${item.item.baseprice}</td>
				<td>${item.item.discount*100}%</td>
				<td>${item.totalPrice}</td>
				<td>${item.quantity}
				</td>
			</tr>
		</logic:iterate>
	</logic:present>
		<tr>
		<td colspan="6" align=right>
		合计：${cartForm.cart.subTotal}
		</td>
	</tr>
	<tr>
		<td colspan="6" align=right>
		<html:form action="/orderAction">
		    <html:hidden property="confirmed" value="true"/>
			<html:submit value="确认" styleClass="normalButton"></html:submit>
			<input type="button" class="normalButton" value="返回购物车"
			onclick="window.location.href='<html:rewrite page="/cartAction.do?method=viewCart"/>'" />
			<input type="hidden" name="method" value="saveOrder"/>
		</html:form>
		</td>
	</tr>
</table>
</div>
       </div>
  </body>
</html>
